// 权限管理接口
import http from '../../utils/request/request'

//获取所有权限
export function getAllPermission(){
    return http({
        url: '/authority/permission',
        method: 'get',
        headers: {'X-Custom-Header': localStorage.getItem("Ip")}
    })
}

//根据角色获取相关权限
export function getPermissionByRole(id){
    return http({
        url: `/authority/permission/rolePermission/${id}`,
        method: 'get',
        headers: {'X-Custom-Header': localStorage.getItem("Ip")}
    })
}